<?php
session_start();
include("head.php"); ?>
    <div class="sui-layout">
		  <div class="sidebar">
<?php include("leftmenu.php"); ?>	  	
		  </div>
		  <div class="content">
			<p class="sui-text-xxlarge my-padd">学生信息查询</p>
			<form action="student-services-list.php" method="get" class="sui-form form-horizontal sui-validate">
				<input type="hidden" name="action" value="add">
				<div class="control-group">
				  <label for="names" class="control-label">姓名：</label>
				  <div class="controls">
					<input name="names" type="text" id="names" class="input-large input-fat" placeholder="输入姓名" data-rules="required|minlength=2|maxlength=10">
				  </div>
                </div>
                <div class="control-group">
			    <label for="xuehao" class="control-label">学号：</label>
			    <div class="controls">
			      <input name="xuehao" type="text" id="xuehao" value="" class="input-large input-fat" placeholder="输入学号" data-rules="required|minlength=2|maxlength=10">
			    </div>
			  </div>
			  <div class="control-group">
			  	<label class="control-label"></label>
			  	<div class="controls">
			  		<input type="submit" value="查询" name="" class="sui-btn btn-large btn-primary">
			  	</div>
			  </div>	  
			</form>
		  </div>
		</div>		
    </div>
<?php include("foot.php"); ?>
<script>
console.log( document.cookie );
var name = document.cookie.split(";")[0].split("=")[1];
console.log(name);
// 推荐使用如下函数来读取cookie：
function getCookie(name){
	var arr,reg=new RegExp("(^| )"+name+"=([^;]*)(;|$)");
	if(arr=document.cookie.match(reg)){
	return unescape(arr[2]);
	}else{
	return null;}
}	
console.log( getCookie("pass"));
var exp = new Date(); 
exp.setTime(exp.getTime() - 1); 
document.cookie= "name=woood;path=/;expires="+exp.toGMTString();
</script>